﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace pardusshipcalc
{
    public partial class CombatCalculator : Form
    {
        int numberOfGuns = 0;

        public CombatCalculator(string gunbox1, string gunbox2, string gunbox3, string gunbox4, string gunbox5)
        {
            InitializeComponent();

            if ((gunbox1 != ":: None ::") && (gunbox1 != ":: Normal Guns ::") && (gunbox1 != ":: Empire Guns ::") && (gunbox1 != ":: Organic ::") && (gunbox1 != ":: Electro-Magnetic ::") && (gunbox1 != ":: Pardus ::") && (gunbox1 != ""))
            {
                numberOfGuns++;
                gunComboBox.Items.Add(gunbox1);
            }
            if ((gunbox2 != ":: None ::") && (gunbox2 != ":: Normal Guns ::") && (gunbox2 != ":: Empire Guns ::") && (gunbox2 != ":: Organic ::") && (gunbox2 != ":: Electro-Magnetic ::") && (gunbox2 != ":: Pardus ::") && (gunbox2 != ""))
            {
                numberOfGuns++;
                gunComboBox.Items.Add(gunbox2);
            }
            if ((gunbox3 != ":: None ::") && (gunbox3 != ":: Normal Guns ::") && (gunbox3 != ":: Empire Guns ::") && (gunbox3 != ":: Organic ::") && (gunbox3 != ":: Electro-Magnetic ::") && (gunbox3 != ":: Pardus ::") && (gunbox3 != ""))
            {
                numberOfGuns++;
                gunComboBox.Items.Add(gunbox3);
            }
            if ((gunbox4 != ":: None ::") && (gunbox4 != ":: Normal Guns ::") && (gunbox4 != ":: Empire Guns ::") && (gunbox4 != ":: Organic ::") && (gunbox4 != ":: Electro-Magnetic ::") && (gunbox4 != ":: Pardus ::") && (gunbox4 != ""))
            {
                numberOfGuns++;
                gunComboBox.Items.Add(gunbox4);
            }
            if ((gunbox5 != ":: None ::") && (gunbox5 != ":: Normal Guns ::") && (gunbox5 != ":: Empire Guns ::") && (gunbox5 != ":: Organic ::") && (gunbox5 != ":: Electro-Magnetic ::") && (gunbox5 != ":: Pardus ::") && (gunbox5 != ""))
            {
                numberOfGuns++;
                gunComboBox.Items.Add(gunbox5);
            }
            
            numberOFGunsLabel.Text = "Guns: " + numberOfGuns.ToString();
        }
    }
}
